@extends('layouts.console_header')

@section('title', '消费订单列表详情')

@section('resources')
    @parent
    <!-- css 文件 -->
	<style>
		.refund_record{margin-top: 20px;background: #fff;padding: 20px;}
		.refund_record .title{border-left: 3px solid #9955c6;color: #9955c6;padding-left: 20px;font-size: 20px;}
		.refund_record .content{margin: 10px 0;overflow: hidden;font-size: 14px;}
		.refund_record .content span{margin-right: 10px;}
	</style>
@endsection

@section('content')
<!--  html内容  -->
<section class="user_list">
	<div style="border-bottom: 2px solid #9955c6;overflow: hidden;">
		<p class="fz_14 account_title fl" style="border: none;"><span style="color: #7f7f7f;">首页>订单管理>消费订单列表></span><span class="co_violet">详情</span></p>
		<a onclick="history.go(-1);" href="#"><p class="fr tc back_btn">返回</p></a>
	</div>
	<table class="WEB_details">
		<tr>
			<td>
				<span>用户昵称：</span>
				<span>{{$nickname}}</span>
			</td>
			<td>
				<span>用户账号：</span>
				<span>{{$mobile}}</span>
			</td>
		</tr>
		<tr>
			<td>
				<span>门店名称：</span>
				<span>{{$shopname}}</span>
			</td>
			<td>
				<span>实付金额：</span>
				<span>{{$actualamount}}</span>
			</td>
		</tr>
		<tr>
			<td>
				<span>联系电话：</span>
				<span>{{$contactnumber}}</span>
			</td>
			<td>
				<span>消费单号：</span>
				<span>{{$ordernumber}}</span>
			</td>
		</tr>
		<tr>
			<td>
				<span>商家地址：</span>
				<span>{{$address}}</span>
			</td>
			<td>
				<span>支付时间：</span>
				<span>{{date('Y-m-d H:i:s', strtotime($created_at))}}</span>
			</td>
		</tr>
	</table>
	<div class="oh">
		<ul class="recharge_progress fl">
			<li>
				<p style="padding-left: 20px;border-left: 3px solid #9955c6;color: #9955c6;margin-left: 20px;font-size: 20px;">消费详情</p>
			</li>
			<li>
				<span class="fl">消费金额</span>
				<span class="fl">{{$orderamount}}</span>
			</li>
			<li>
				<span class="fl">红包</span>
				<span class="fl">{{$redenvelopeamount}}</span>
			</li>
			<li>
				<span class="fl">实付金额</span>
				<span class="fl">{{$actualamount}}</span>
			</li>
			<li>
				<span class="fl">财务结款额（元）</span>
				<span class="fl">{{$accountamount}}</span>
			</li>
		</ul>
		<ul class="recharge_progress fl" style="margin-left: 50px;">
			<li>
				<p style="color: #9955c6;font-size: 20px;">红包详情</p>
			</li>
			<li style="height: 120px;">
				<div class="oh">
					<span class="fl">使用红包</span>
					<span class="fl">{{$redenvelopeamount}}</span>
					@if(isset($userredenvelope['endtime']))
						<span class="fl">(平台:{{$userredenvelope['hqamount']}};</span>
						<span class="fl">代理商:{{$userredenvelope['agentamount']}};)</span>
					@endif
				</div>
				@if(isset($userredenvelope['endtime']))
					<div class="oh" style="margin-left:240px;">
						<span class="fl" style="padding: 0;width: 200px;margin: 0;text-align: center;">限{{$userredenvelope['cityname']}}使用</span>
						<span class="fl" style="padding: 0;width: 200px;margin: 0;text-align: center;">有效期至 {{date('Y-m-d', strtotime($userredenvelope['endtime']))}}</span>
					</div>
				@endif
			</li>
			<li style="height: 120px;">
				<div class="oh">
					<span class="fl">挣取红包</span>
					<span class="fl">{{$bonus}}</span>
					@if(isset($sendredenvelope['endtime']))
						<span class="fl">(平台:{{$sendredenvelope['hqamount']}}</span>
						<span class="fl">代理商: {{$sendredenvelope['agentamount']}})</span>
					@endif

				</div>
				<div class="oh" style="margin-left:240px;">
				@if(isset($sendredenvelope['endtime']))
					<span class="fl" style="padding: 0;width: 200px;margin: 0;text-align: center;">限{{$sendredenvelope['cityname']}}使用</span>
					<span class="fl" style="padding: 0;width: 200px;margin: 0;text-align: center;">有效期至 {{date('Y-m-d', strtotime($sendredenvelope['endtime']))}}</span>
				@endif
				</div>
			</li>
			{{--<li style="height: 60px;">--}}
				{{--<div class="oh">--}}
					{{--<span class="fl">限{{$redenveoplecityname}}使用</span>--}}
					{{--<span class="fl">有效期至 {{date('Y-m-d', strtotime($redenveopleendtime))}}</span>--}}
				{{--</div>--}}
			{{--</li>--}}
		</ul>
	</div>
	@if($refundstatus)
	<div class="refund_record">
		<p class="title" style="">退款记录</p>
		<p class="content">
			<span class="fl">操作人员：</span>
			<span class="fl">{{$refundinfo['adminname']}}</span>
			<span class="fl">{{$refundinfo['adminmobile']}}</span>
		</p>
		<p class="content">
			<span class="fl">操作时间：</span>
			<span class="fl">{{date('Y-m-d H:i:s', strtotime($refundinfo['created_at']))}}</span>
		</p>
		<p class="content">
			<span class="fl">退款金额：</span>
			<span class="fl">{{$refundinfo['money']}} 退回至用户的余额</span>
		</p>
		<p class="content">
			<span class="fl">红包变更：</span>
			<span class="fl">{{$refundinfo['redenvelopeinfo']}}</span>
		</p>
		<p class="content">
			<span class="fl">退款备注：</span>
			<span class="fl">{{$refundinfo['remark']}}</span>
		</p>
	</div>
	@endif
</section>
@endsection

@section('scriptResources')
    @parent
    <!-- js 文件-->

@endsection